from flask import Blueprint, request, render_template,\
    redirect, url_for
from apps.user.model import User
from ext import db

user_bp = Blueprint('user', __name__)

users = []


def addUser():
    user = User()
    user.username = 'zhang'
    user.password = "zhang000001"
    user.phone = "15671602133"
    db.session.add(user)
    db.session.commit()

@user_bp.route('/')
def user_center():
    users = User.query.all()
    return render_template('user/user_center.html', users = users)

